<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>

	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<title>Insert title here</title>
	</head>

	<body>
		<div>
			<form action="ASAjax" method="post" class="pageForm required-validate" onsubmit="return validateCallback(this, dialogAjaxDone);">
				<div class="pageFormContent" layoutH="56">
					<p>
						<label>部门名称X：</label>
						<!-- 单击文本框直接弹出搜索dialog -->
						<input name="users1.e_name" value="" suggestFields="e_name" suggestUrl="BlankAjax" lookupGroup="users1" type="text" class="required" id="lookup1"/>
						<!--<input name="user1.e_name" type="text" value="">
						可以用普文本框接收但是弹出框层级会比当前dialog低，所以还是用一个返回为空的Servlet当suggestUrl-->
						<a href="LookUpBackAjax" lookupGroup="users1" id="xx"></a>
					</p>
					<p>
						<label>部门名称A：</label>
						<input id="id1" name="users1.id" value="" type="hidden">
						<input name="users1.e_name" value="" suggestFields="e_name" suggestUrl="LookUpAjax" lookupGroup="users1" type="text" class="required" />
						<a class="btnLook" href="LookUpBackAjax" lookupGroup="users1">查找带回</a>
					</p>	
					<p>
						<label>部门名称B：</label>
						<input name="users2.e_name" value="" suggestFields="e_name" suggestUrl="LookUpAjax?uid={id1}" lookupGroup="users2" type="text" class="required" />
						<a class="btnLook" href="LookUpBackAjax?uid={id1}" lookupGroup="users2">查找带回</a>		
					</p>	
				</div>
				<div class="formbar">
					<ul>
						<li><div class="buttonActive"><div class="buttonContent"><button id="submitbtn" type="submit">保存</button></div></div></li>
						<li><div class="button"><div class="buttonContent"><button type="button" class="close">取消</button></div></div>	</li>
					</ul>
				</div>
			</form>
		</div>
		
		<script type="text/javascript">
			$(function(){
				$("#lookup1").click(function(){
					$("#xx").click();
				});
			});
		</script>
		
	</body>

</html>